package psico_test.appCrear.ensayo;

import psico_test.appCrear.appCrear;
import psico_test.appCrear.ensayo.gui.ventanaEnsayo;

public class EnsayoManager extends Thread
{
	private appCrear parent;
	private Thread threadGui;
	private ventanaEnsayo gui;
	
	public EnsayoManager (appCrear parent)
	{
		this.parent = parent;
	}

	public void run()
	{
		gui = new ventanaEnsayo(this);
		threadGui = new Thread(gui);
		threadGui.run();
	}
	
	public void addEnsayo( Object[]ensayo)
	{
		gui.dispose();
		threadGui.stop();
		parent.addEnsayo(ensayo);
	}
}
